package com.alkalinesolutions.json.core;

/**
 * Indicates the JSON text uses the same key for two entries within the same
 * object.
 * 
 * @author David Waite &lt;<a href='mailto:david@alkaline-solutions.com'>david@alkaline-solutions.com</a>&gt;
 * 
 */
public class DuplicateKeyException extends JSONException {
	private static final long serialVersionUID = 1L;

	public DuplicateKeyException(final String keyName) {
		super(keyName);
	}

	@Override
	public String getMessage() {
		return String
				.format(
						Messages.getString("DuplicateKeyException.message"), super.getMessage()); //$NON-NLS-1$
	}
}